<%--
  Created by IntelliJ IDEA.
  User: z5727
  Date: 2022/9/21
  Time: 0:24
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
<c:set value="${pageContext.request.contextPath}" var="path"></c:set>
<table class="table table-hover align-middle ">
<thead>
<tr>
    <th class="pxp-is-checkbox" style="width: 1%;"><input type="checkbox" class="form-check-input select_all"></th>
    <th style="width: 25%;">工作</th>
    <th style="width: 15%;">公司</th>
    <th style="width: 20%;">类别</th>
    <th style="width: 12%;">是否全职</th>
    <th>日期<span class="fa fa-angle-up ms-3"></span></th>
    <th>&nbsp;</th>
</tr>
</thead>
<tbody>
<c:forEach items="${requestScope.concernPositionPageInfo.list}" var="concernPosition">
<tr>
    <td><input type="checkbox" class="form-check-input select_one" data-id="${concernPosition.id}"></td>
    <td>
        <a href="/web/personal/positionDetail/${concernPosition.position.id}" target="_blank">
            <div class="pxp-candidate-dashboard-job-title">${concernPosition.position.positionName}</div>
            <div class="pxp-candidate-dashboard-job-location"><span class="fa fa-globe me-1"></span>${concernPosition.position.company.province.provName}  ${concernPosition.position.company.city.cityName}</div>
        </a>
    </td>
    <td><a href="/web/personal/personalCompanyDetail/${concernPosition.position.company.id}" target="_blank" class="pxp-candidate-dashboard-job-company">${concernPosition.position.company.name}</a></td>
    <td><div class="pxp-candidate-dashboard-job-category">${concernPosition.position.positionTypeSecond.typeName}</div></td>
    <c:if test="${concernPosition.position.fullTimeOn eq true}" var="isCur">
    <td><div class="pxp-candidate-dashboard-job-type">全职</div></td>
    </c:if>
    <c:if test="${not isCur}"><td><div class="pxp-candidate-dashboard-job-type">兼职</div></td></c:if>
    <td><div class="pxp-candidate-dashboard-job-date mt-1"><fmt:formatDate value="${concernPosition.attentionTime}" pattern="yyyy-MM-dd hh:mm:ss"></fmt:formatDate></div></td>
    <td>
        <div class="pxp-dashboard-table-options">
            <ul class="list-unstyled">
<%--                <li><button title="Preview"><span class="fa fa-eye"></span></button></li>--%>
                <li><button title="Delete" class="delete_one" data-id="${concernPosition.id}"><span class="fa fa-trash-o"></span></button></li>
            </ul>
        </div>
    </td>
</tr>
</c:forEach>
</tbody>
</table>

<div class="row mt-4 mt-lg-5 justify-content-between align-items-center">
    <div class="col-auto" data-id="${requestScope.concernPositionPageInfo.total}">
        <nav class="mt-3 mt-sm-0" aria-label="Jobs list pagination">
            <ul class="pagination pxp-pagination">
                <c:forEach items="${requestScope.concernPositionPageInfo.navigatepageNums}" var="pageNum">
                <c:if test="${requestScope.concernPositionPageInfo.pageNum eq pageNum}" var="isCur">
                <li class="page-item active" aria-current="page">
                    <span class="page-link">${pageNum}</span>
                </li>
                </c:if>
                <c:if test="${not isCur}">
                <li class="page-item"><a class="page-link" href="javascript:void(0)">${pageNum}</a></li>
                </c:if>
                </c:forEach>
            </ul>
        </nav>
    </div>
</div>